package threadDemo08;

public class TestDemo {
    public static void main(String[] args) throws InterruptedException {
        /**
         *  public final void join()插入线程
         */

        MyThread myThread =new MyThread();
        myThread.setName("田想");
        myThread.start();
        //表示把myThread这个线程插入到当前线程之前
        //myThread:田想
        //当前线程:main线程
        myThread.join();

        for (int i = 0; i < 10; i++) {
            System.out.println(i);
        }
    }
}
